<?php

$id_product=$_REQUEST["id_product"];
$id_company=$_REQUEST["id_company"];

include '../operations/connection.php';

//$result=mysql_query("SELECT * FROM warranty w WHERE w.id_company='$id_company' AND w.id_product='$id_product'");
//$co=0;
//while (mysql_fetch_array($result)){
//	$co++;
//}
//if($co>0){
//	echo '0';
//}else{
	mysql_query("INSERT INTO `warranty` (`id_product`, `id_company`) VALUES ('$id_product', '$id_company')");
//	echo '1'';
//}

mysql_close($connection);
?>